package com.yjt.gcss.gddw.common.dao;

import java.util.ArrayList;
import java.util.Collection;

import org.hibernate.criterion.MatchMode;
import org.hibernate.criterion.Order;
import org.springframework.stereotype.Service;

import com.yjt.common.hibernate.base.AbstractDaoImpl;
import com.yjt.common.hibernate.base.DaoException;
import com.yjt.gcss.gddw.common.bean.domain.UiSsdsCz;

@Service(UiSsdsCzDao.BEAN_PACKAGE_NAME)
public class UiSsdsCzDao extends AbstractDaoImpl{
	public static final String BEAN_PACKAGE_NAME = "com.yjt.gcss.gddw.common.dao.UiSsdsCzDao";
    
	public UiSsdsCzDao(){
		
	}
	
	public UiSsdsCz getBeanById(String id) throws DaoException {
		return (UiSsdsCz) getBeanById(UiSsdsCz.BEAN_PACKAGE_NAME, id, false);
	}
	
	public UiSsdsCz getBeanByIdForUpdate(String id) throws DaoException {
		return (UiSsdsCz) getBeanById(UiSsdsCz.BEAN_PACKAGE_NAME, id, true);
	}

	@SuppressWarnings("rawtypes")
	public Collection getAll() throws DaoException {
		return getAll(UiSsdsCz.BEAN_PACKAGE_NAME);
	}

	@SuppressWarnings("rawtypes")
	public UiSsdsCz getBeanByParams(String hqlName,ArrayList paraList) throws DaoException{
		return (UiSsdsCz) getProtoBeanByParams(hqlName,paraList);
	}

	public UiSsdsCz getBeanByBean(UiSsdsCz bean, MatchMode mode) throws DaoException{
		return (UiSsdsCz) getProtoBeanByBean(bean, mode);
	}
	
	public UiSsdsCzDao setOrder(Order order){
		return (UiSsdsCzDao)super.addOrder(order);
	}
	
	public UiSsdsCz getBeanById(String id,boolean lock){
		return (UiSsdsCz) getBeanById(UiSsdsCz.BEAN_PACKAGE_NAME,id,lock);
	}

}
